package cn.touna.jss.common.properties.disconf;

import com.baidu.disconf.client.common.annotations.DisconfFile;
import com.baidu.disconf.client.common.annotations.DisconfFileItem;
import org.springframework.stereotype.Component;

@Component
@DisconfFile(filename = "sifa.properties", targetDirPath = "disconf")
public class SifaProperties {

    private  String uid = "test";

    private String pwd = "12qw90op";

    private Integer expire = 0;

    private String requestUrl = "https://data.court.gov.cn/shesu/test/api/entout/portrait/orgg";

    public void setUid(String uid) {
        this.uid = uid;
    }

    public void setPwd(String pwd) {
        this.pwd = pwd;
    }

    public void setExpire(Integer expire) {
        this.expire = expire;
    }

    public void setRequestUrl(String requestUrl) {
        this.requestUrl = requestUrl;
    }

    @DisconfFileItem(name = "sifa.uid", associateField = "uid")
    public String getUid() {
        return uid;
    }

    @DisconfFileItem(name = "sifa.pwd", associateField = "pwd")
    public String getPwd() {
        return pwd;
    }

    @DisconfFileItem(name = "sifa.expire", associateField = "expire")
    public Integer getExpire() {
        return expire;
    }

    @DisconfFileItem(name = "sifa.requestUrl", associateField = "requestUrl")
    public String getRequestUrl() {
        return requestUrl;
    }
}
